const Koa = require('koa');
const bodyParser = require('koa-bodyparser');
const koaRouter = require('koa-router');
const routes = require('./routes')
const app = new Koa();

app.use(bodyParser());
const router = koaRouter();

// 添加路由
routes(app, router)

app.use(router.routes());
app.use(require('koa-static')('./www'));
app.listen(3001);
